$def with (cur)
<article>
<header>
<h1>Edit Groups</h1>
<p>Create groups by adding the start ip and end ip and name to group. Deleting group will delete all entries of macs under it</p>
</header>
<section>
<h2>Groups Table</h2>
<p>
<table>
	<tr>
		<th>Id</th>
		<th>Name</th>
		<th>IP range start</th>
		<th>IP range end</th>
		<th>gateway</th>
		<th>ntp_servers</th>
		<th>domain_name_servers</th>
		<th>domain_name</th>
		<th>Delete</th>
		<th>Update</th>
	<tr>
$for row in cur:
	<tr>
	<form method=POST>
		<td><a href="/maps?group=${row[0]}" > ${row[0]}</a></td>
		<td><input type=text name=name value=$row[1]></td>
		<td><input type=text name=start_ip_int value=$str(IP(row[2]))></td>
		<td><input type=text name=end_ip_int value=$str(IP(row[3]))></td>
		<td><input type=text name=gateway value=$row[4]></td>
		<td><input type=text name=domain_name value=$row[5]></td>
		<td><input type=text name=domain_name_servers value=$row[6]></td>
		<td><input type=text name=ntp_servers value=$row[7]></td>
		<td>
			<input type=hidden name=id value=$row[0]>
			<input type=submit name=Action value=Delete>
		</td>
		<td>
			<input type=submit name=Action value=Update>
		</td>
	</form>
	<tr>
<tr>
	<form method=POST>
		<td></td>
		<td><input type=text name=name></td>
		<td><input type=text name=start_ip_int></td>
		<td><input type=text name=end_ip_int></td>
		<td><input type=text name=gateway></td>
		<td><input type=text name=domain_name></td>
		<td><input type=text name=domain_name_servers></td>
		<td><input type=text name=ntp_servers></td>
		<td>
		</td>
		<td>
			<input type=submit name=Action value=Add>
		</td>
	</form>
	<tr>
</table>
</p>
</section>
</article>
